/*
 * Reflexis is Copyright (C) 2007, by it-raum.ch
 * martin.imobersteg@it-raum.ch
 *
 * It is free software; you can redistribute it and/or modify it under the terms of either:
 * a) the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version, or
 * b) the "Artistic License".
 */

#include <QtGui>

#include "Reflexis.h"

int main(int argc, char *argv[])
{
	QApplication app(argc, argv);

	QCoreApplication::setOrganizationName("it-raum");
	QCoreApplication::setOrganizationDomain("it-raum.ch");
	QCoreApplication::setApplicationName("reflexis");

	if (!QSystemTrayIcon::isSystemTrayAvailable()) {
		QMessageBox::critical(0, QObject::tr("Reflexis"),
			QObject::tr("I couldn't detect any system tray on this system."));
		return 1;
	}

	QPixmap pixmap(":img/splash.png");
	QSplashScreen splash(pixmap);
	splash.show();
	splash.showMessage(QString("Reflexis %1 (c) 2007 it-raum.ch").arg(REFLEXIS_VERSION), Qt::AlignLeft | Qt::AlignBottom);

	QTimer::singleShot(3000, &splash, SLOT(hide()));

	Reflexis reflexis;
	return app.exec();
}
